{#**
*
* 功能描述（模板）
*
* @author suoya <jlusuoya@gmail.com>
* @version 1
*#}

{#include file="header.tpl" title="标题" #}
<div class="content middle">
    <div class="main">
        <form action="index.php?action=login.login" method="POST" class="ui form">
            <div class="content"></div>
            <div class="login">
                <div class="ui form message">
                    <div class="inputDIV">
                        <label class="title" style="width: 100%; text-align: left; color: #555555;">用户名</label>
                        <div class="ui input" style="width: 100%;">
                            <input type="text" name="username" class="input_username">
                        </div>
                    </div>
                    <div class="inputDIV">
                        <label class="title" style="width: 100%; text-align: left; color: #555555;">密码</label>
                        <div class="ui input" style="width: 100%;">
                            <input type="password" name="password" class="input_password">
                        </div>
                    </div>
                    <div class="ui error message"></div>
                    <div class="button_bar" style="padding-top: 10px;">
                        <input class="login_button" type="submit" value="登录" />
                    </div>
                </div> 
            </div>
        </form>
    </div>
</div>
{#include file="footer.tpl"#}
<script>
    $('.ui.form').form({
        username: {
            identifier: 'username',
            rules: [
                {
                    type: 'empty',
                    prompt: '请输入用户名'
                }
            ]
        },
        password: {
            identifier: 'password',
            rules: [
                {
                    type: 'empty',
                    prompt: '请输入密码'
                },
                {
                    type: 'length[6]',
                    prompt: '密码最少六位'
                }
            ]
        }
    });

    $(document).ready(function() {
        $(".input_username").focus();
    });
</script>
